package com.example.martian.huobi.constant;

import com.example.martian.huobi.constant.enums.ExchangeEnum;
import lombok.*;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

@Builder
@AllArgsConstructor
@NoArgsConstructor
@ToString
@ConfigurationProperties(prefix = "huobi")
@Data
public class HuobiOptions implements Options {

  @Builder.Default
  private String restHost = "https://api.huobi.pro";

  @Builder.Default
  private String websocketHost = "wss://api.huobi.pro";

  private String apiKey;

  private String secretKey;

  @Builder.Default
  private boolean websocketAutoConnect = true;


  @Override
  public ExchangeEnum getExchange() {
    return ExchangeEnum.HUOBI;
  }

  @Override
  public String getRestHost() {
    return this.restHost;
  }

  @Override
  public String getWebSocketHost() {
    return this.websocketHost;
  }

  @Override
  public boolean isWebSocketAutoConnect() {
    return this.websocketAutoConnect;
  }

}
